package org.example.servicemanage.client;

import org.example.model.wx.bean.Message;
import org.example.model.wx.bean.Token;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

@FeignClient(value = "service-wx", url = "https://api.weixin.qq.com")
public interface WXFeignClient {
    @GetMapping("/cgi-bin/token")
    Token getToken(String grant_type, String appid, String secret);

    @PostMapping("/cgi-bin/message/mass/send")
    String sendMassMessage(String access_token, @RequestBody Message json);
}
